<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title></title>
</head>
<body>
<script type="text/javascript">
    var basePath = "http://www.dd.com/base";
</script>
<form class="form-horizontal" role="form" id="form">

    <div class="form-group">
        <label for="content" class="col-sm-2 control-label">bb</label>
        <div  class="col-sm-10">
            <div id="content" class="cc-Editor" remark="必须选择一样" initValue="1"  style="width: 200px"></div>
        </div>
    </div>
    <div class="form-group">
        <div class="col-sm-offset-2 col-sm-10">
            <input type="button" value="getAddData" onclick="getAddData()">
            <input type="button" value="getEditData" onclick="getEditData()">
            <input type="button" value="setValue" onclick="setValue()">
            <input type="button" value="getValue" onclick="getValue()">
        </div>
    </div>
</form>

<script type="text/javascript" src="../lib/jquery/jquery-1.10.2.min.js"></script>
<script type="text/javascript" src="../lib/layer/layer.js"></script>

<script type="text/javascript" src="../lib/handlebars/handlebars-v4.0.5.js"></script>
<script type="text/javascript" src="../lib/handlebars/handlebars-extend.js"></script>

<link href="../lib/bootstrap/css/bootstrap.min.css" rel="stylesheet" />
<script type="text/javascript" src="../lib/bootstrap/js/bootstrap.min.js"></script>

<script type="text/javascript"  src="../lib/common/common.js"></script>

<script type="text/javascript" src="../lib/ueditor/ueditor.config.js"></script>
<script type="text/javascript" src="../lib/ueditor/ueditor.all.js"></script>
<script type="text/javascript" src="../lib/ueditor/lang/zh-cn/zh-cn.js"></script>

<link type="text/css" href="../lib/component/css/cc.css" rel="stylesheet" />
<script type="text/javascript"  src="../lib/component/js/cc.js"></script>

<script type="text/javascript">
    $(function(){
       _$.parser.parse()
    });
    function getAddData(){

        var form = new _$.Form("#form");
        var values = form.getAddData();
        alert(JSON.stringify(values))
    }
    function getEditData(){

        var form = new _$.Form("#form");
        var values = form.getEditData();
        alert(JSON.stringify(values))
    }

    function setValue(){
        var editor = _$.getById("content");
        editor.setValue("fffffffff");
    }
    function getValue(){
        var editor = _$.getById("content");
       var str = editor.getValue();
        alert(str)
    }
</script>
</body>
</html>
